<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Calico: calico/sensors/accelerometer.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Calico
   </div>
   <div id="projectbrief">A visual-inertial calibration library designed for rapid problem construction and debugging.</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_e7ac338090e46d594d3ea7a0e9efc7ba.html">calico</a></li><li class="navelem"><a class="el" href="dir_a7e6fdbe7254e0dadcd82a69dc076109.html">sensors</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">accelerometer.h</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifndef CALICO_SENSORS_ACCELEROMETER_H_</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#define CALICO_SENSORS_ACCELEROMETER_H_</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160; </div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#include &lt;string&gt;</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="preprocessor">#include &lt;vector&gt;</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160; </div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &quot;absl/container/flat_hash_map.h&quot;</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#include &quot;absl/status/status.h&quot;</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor">#include &quot;absl/strings/string_view.h&quot;</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor">#include &quot;calico/sensors/sensor_base.h&quot;</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="preprocessor">#include &quot;calico/sensors/accelerometer_models.h&quot;</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="preprocessor">#include &quot;calico/trajectory.h&quot;</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="preprocessor">#include &quot;calico/typedefs.h&quot;</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="preprocessor">#include &quot;ceres/problem.h&quot;</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="preprocessor">#include &quot;Eigen/Dense&quot;</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160; </div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160; </div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="keyword">namespace </span><a class="code" href="namespacecalico_1_1sensors.html">calico::sensors</a> {</div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160; </div>
<div class="line"><a name="l00023"></a><span class="lineno"><a class="line" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">   23</a></span>&#160;<span class="keyword">struct </span><a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">AccelerometerObservationId</a> {</div>
<div class="line"><a name="l00025"></a><span class="lineno"><a class="line" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a4e90d646ca44f8d9b7bff65c95d6462c">   25</a></span>&#160;  <span class="keywordtype">double</span> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a4e90d646ca44f8d9b7bff65c95d6462c">stamp</a>;</div>
<div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a8713942f102169b91a719ca40f42d9ac">   27</a></span>&#160;  <span class="keywordtype">int</span> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a8713942f102169b91a719ca40f42d9ac">sequence</a>;</div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160; </div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;  <span class="keyword">template</span> &lt;<span class="keyword">typename</span> H&gt;</div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;  <span class="keyword">friend</span> H AbslHashValue(H h, <span class="keyword">const</span> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">AccelerometerObservationId</a>&amp; <span class="keywordtype">id</span>) {</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;    <span class="keywordflow">return</span> H::combine(std::move(h), <span class="keywordtype">id</span>.<a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a4e90d646ca44f8d9b7bff65c95d6462c">stamp</a>, <span class="keywordtype">id</span>.<a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a8713942f102169b91a719ca40f42d9ac">sequence</a>);</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;  }</div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;  <span class="keyword">friend</span> <span class="keywordtype">bool</span> operator==(<span class="keyword">const</span> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">AccelerometerObservationId</a>&amp; lhs,</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;                         <span class="keyword">const</span> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">AccelerometerObservationId</a>&amp; rhs) {</div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;    <span class="keywordflow">return</span> (lhs.<a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a4e90d646ca44f8d9b7bff65c95d6462c">stamp</a> == rhs.<a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a4e90d646ca44f8d9b7bff65c95d6462c">stamp</a> &amp;&amp;</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;            lhs.<a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a8713942f102169b91a719ca40f42d9ac">sequence</a> == rhs.<a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a8713942f102169b91a719ca40f42d9ac">sequence</a>);</div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;  }</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;};</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160; </div>
<div class="line"><a name="l00041"></a><span class="lineno"><a class="line" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html">   41</a></span>&#160;<span class="keyword">struct </span><a class="code" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html">AccelerometerMeasurement</a> {</div>
<div class="line"><a name="l00043"></a><span class="lineno"><a class="line" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html#ac08ec8f7529613c599bc84a25900df96">   43</a></span>&#160;  Eigen::Vector3d <a class="code" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html#ac08ec8f7529613c599bc84a25900df96">measurement</a>;</div>
<div class="line"><a name="l00045"></a><span class="lineno"><a class="line" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html#a22dd6e5ae79698f60cb08f060e36be46">   45</a></span>&#160;  <a class="code" href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">AccelerometerObservationId</a> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html#a22dd6e5ae79698f60cb08f060e36be46">id</a>;</div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;};</div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160; </div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160; </div>
<div class="line"><a name="l00050"></a><span class="lineno"><a class="line" href="classcalico_1_1sensors_1_1Accelerometer.html">   50</a></span>&#160;<span class="keyword">class </span><a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a> : <span class="keyword">public</span> <a class="code" href="classcalico_1_1sensors_1_1Sensor.html">Sensor</a> {</div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160; <span class="keyword">public</span>:</div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;  <span class="keyword">explicit</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a>() = <span class="keywordflow">default</span>;</div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;  <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a>(<span class="keyword">const</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a>&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;  <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a>&amp; operator=(<span class="keyword">const</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a>&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;  ~<a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html">Accelerometer</a>() = <span class="keywordflow">default</span>;</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160; </div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a69c802ad172b3875992298cbde1399e1">SetName</a>(<span class="keyword">const</span> std::string&amp; name) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;  <span class="keyword">const</span> std::string&amp; <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#ac11dda7c2c1c93091c5d3544b867a761">GetName</a>() <span class="keyword">const</span> <span class="keyword">final</span>;</div>
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a0babbee636013d6224b1908b5c8c4ec7">SetExtrinsics</a>(<span class="keyword">const</span> <a class="code" href="classcalico_1_1Pose3.html">Pose3d</a>&amp; T_sensorrig_sensor) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;  <span class="keyword">const</span> <a class="code" href="classcalico_1_1Pose3.html">Pose3d</a>&amp; <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a3461a72e36066b1e22778a18525873bf">GetExtrinsics</a>() <span class="keyword">const</span> <span class="keyword">final</span>;</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#acd8424db4c5a76a33a113963e763eaa6">SetIntrinsics</a>(<span class="keyword">const</span> Eigen::VectorXd&amp; intrinsics) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;  <span class="keyword">const</span> Eigen::VectorXd&amp; <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a046cef74dd6478b5001d5b5392d866bd">GetIntrinsics</a>() <span class="keyword">const</span> <span class="keyword">final</span>;</div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#aab53d1ea391bcffe744ad1c5e77ea893">SetLatency</a>(<span class="keywordtype">double</span> latency) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;  <span class="keywordtype">double</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a6a4922add5c71301ac6dd55a63a2ea96">GetLatency</a>() <span class="keyword">const</span> <span class="keyword">final</span>;</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#aaa70cd751e2a85322a44461df1ba8b41">EnableExtrinsicsEstimation</a>(<span class="keywordtype">bool</span> enable) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#ac67ee592eac447f77f3570cc3d1f7955">EnableIntrinsicsEstimation</a>(<span class="keywordtype">bool</span> enable) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#ac9cdfe615bc666967c5c72231cd23b60">EnableLatencyEstimation</a>(<span class="keywordtype">bool</span> enable) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a4b441d544eafab8b86c867a27b5147a8">SetLossFunction</a>(<a class="code" href="namespacecalico_1_1utils.html#aacede3df540b75d2e131f113380f0ce9">utils::LossFunctionType</a> loss, <span class="keywordtype">double</span> scale) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;  absl::StatusOr&lt;int&gt; <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#ad662a04d9dc1fa620d674260a10ef584">AddParametersToProblem</a>(ceres::Problem&amp; problem) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;  absl::StatusOr&lt;int&gt; <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a18f345438e5d1c919e8a2842491552fd">AddResidualsToProblem</a>(</div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;      ceres::Problem &amp; problem,</div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;      <a class="code" href="classcalico_1_1Trajectory.html">Trajectory</a>&amp; sensorrig_trajectory,</div>
<div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;      <a class="code" href="classcalico_1_1WorldModel.html">WorldModel</a>&amp; world_model) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a1939986d8304f60a1ed2d67dfd6efd1e">SetMeasurementNoise</a>(<span class="keywordtype">double</span> sigma) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#aa6bd00426c947a719e8889a8c9671447">UpdateResiduals</a>(ceres::Problem&amp; problem) <span class="keyword">final</span>;</div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a7a7b63e21eb8358ba98f78ee9cdb5d25">ClearResidualInfo</a>() <span class="keyword">final</span>;</div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160; </div>
<div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160; </div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;  absl::StatusOr&lt;std::vector&lt;AccelerometerMeasurement&gt;&gt; <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#ac1e574412a12a2dad447b6a7b3fe2855">Project</a>(</div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;      <span class="keyword">const</span> std::vector&lt;double&gt;&amp; interp_times,</div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;      <span class="keyword">const</span> <a class="code" href="classcalico_1_1Trajectory.html">Trajectory</a>&amp; sensorrig_trajectory,</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;      <span class="keyword">const</span> <a class="code" href="classcalico_1_1WorldModel.html">WorldModel</a>&amp; world_model) <span class="keyword">const</span>;</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160; </div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a35c7bedfecf5338f29bd3518476eed29">SetModel</a>(<a class="code" href="namespacecalico_1_1sensors.html#a911841171d662dc3e4bf4b39463a4c42">AccelerometerIntrinsicsModel</a> accelerometer_model);</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160; </div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;  <a class="code" href="namespacecalico_1_1sensors.html#a911841171d662dc3e4bf4b39463a4c42">AccelerometerIntrinsicsModel</a> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a3bbd02b0dec4641a5b012dc19f4dd006">GetModel</a>() <span class="keyword">const</span>;</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160; </div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160; </div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#ae3b0b45306c07f8af56bcd42cdc3cbab">AddMeasurement</a>(<span class="keyword">const</span> <a class="code" href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html">AccelerometerMeasurement</a>&amp; measurement);</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160; </div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160; </div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;  absl::Status <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#aaaac1bf62c3b01d64ce320d5cde74453">AddMeasurements</a>(</div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;      <span class="keyword">const</span> std::vector&lt;AccelerometerMeasurement&gt;&amp; measurements);</div>
<div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160; </div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;  <span class="keywordtype">void</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a572707e00c6b6acc67e61699ca8c436d">ClearMeasurements</a>();</div>
<div class="line"><a name="l00118"></a><span class="lineno">  118</span>&#160; </div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;  <span class="keywordtype">int</span> <a class="code" href="classcalico_1_1sensors_1_1Accelerometer.html#a60bb4adcaedefd9022a7771445618fba">NumberOfMeasurements</a>() <span class="keyword">const</span>;</div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160; </div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160; <span class="keyword">private</span>:</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;  std::string name_;</div>
<div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160;  <span class="keywordtype">bool</span> intrinsics_enabled_;</div>
<div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;  <span class="keywordtype">bool</span> extrinsics_enabled_;</div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;  <span class="keywordtype">bool</span> latency_enabled_;</div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;  std::unique_ptr&lt;AccelerometerModel&gt; accelerometer_model_;</div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;  <a class="code" href="classcalico_1_1Pose3.html">Pose3d</a> T_sensorrig_sensor_;</div>
<div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;  Eigen::VectorXd intrinsics_;</div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;  <span class="keywordtype">double</span> latency_ = 0.0;</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;  <span class="keywordtype">double</span> sigma_ = 1.0;</div>
<div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;  <a class="code" href="namespacecalico_1_1utils.html#aacede3df540b75d2e131f113380f0ce9">utils::LossFunctionType</a> loss_function_;</div>
<div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;  <span class="keywordtype">double</span> loss_scale_ = 1.0;</div>
<div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;  absl::flat_hash_map&lt;AccelerometerObservationId, AccelerometerMeasurement&gt;</div>
<div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;      id_to_measurement_;</div>
<div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;  absl::flat_hash_map&lt;AccelerometerObservationId, Eigen::Vector3d&gt; id_to_residual_;</div>
<div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160;  absl::flat_hash_map&lt;AccelerometerObservationId, ceres::ResidualBlockId&gt;</div>
<div class="line"><a name="l00138"></a><span class="lineno">  138</span>&#160;      id_to_residual_id_;</div>
<div class="line"><a name="l00139"></a><span class="lineno">  139</span>&#160;};</div>
<div class="line"><a name="l00140"></a><span class="lineno">  140</span>&#160; </div>
<div class="line"><a name="l00141"></a><span class="lineno">  141</span>&#160;} <span class="comment">// namespace calico::sensors</span></div>
<div class="line"><a name="l00142"></a><span class="lineno">  142</span>&#160; </div>
<div class="line"><a name="l00143"></a><span class="lineno">  143</span>&#160;<span class="preprocessor">#endif </span><span class="comment">// CALICO_SENSORS_ACCELEROMETER_H_</span></div>
<div class="ttc" id="aclasscalico_1_1Pose3_html"><div class="ttname"><a href="classcalico_1_1Pose3.html">calico::Pose3&lt; double &gt;</a></div></div>
<div class="ttc" id="aclasscalico_1_1Trajectory_html"><div class="ttname"><a href="classcalico_1_1Trajectory.html">calico::Trajectory</a></div><div class="ttdef"><b>Definition:</b> trajectory.h:25</div></div>
<div class="ttc" id="aclasscalico_1_1WorldModel_html"><div class="ttname"><a href="classcalico_1_1WorldModel.html">calico::WorldModel</a></div><div class="ttdef"><b>Definition:</b> world_model.h:73</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html">calico::sensors::Accelerometer</a></div><div class="ttdoc">Accelerometer class.</div><div class="ttdef"><b>Definition:</b> accelerometer.h:50</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a046cef74dd6478b5001d5b5392d866bd"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a046cef74dd6478b5001d5b5392d866bd">calico::sensors::Accelerometer::GetIntrinsics</a></div><div class="ttdeci">const Eigen::VectorXd &amp; GetIntrinsics() const final</div><div class="ttdoc">Getter for intrinsics parameters.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:162</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a0babbee636013d6224b1908b5c8c4ec7"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a0babbee636013d6224b1908b5c8c4ec7">calico::sensors::Accelerometer::SetExtrinsics</a></div><div class="ttdeci">void SetExtrinsics(const Pose3d &amp;T_sensorrig_sensor) final</div><div class="ttdoc">Setter for extrinsics parameters.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:139</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a18f345438e5d1c919e8a2842491552fd"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a18f345438e5d1c919e8a2842491552fd">calico::sensors::Accelerometer::AddResidualsToProblem</a></div><div class="ttdeci">absl::StatusOr&lt; int &gt; AddResidualsToProblem(ceres::Problem &amp;problem, Trajectory &amp;sensorrig_trajectory, WorldModel &amp;world_model) final</div><div class="ttdoc">Contribue this sensor's residuals to the ceres problem.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:35</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a1939986d8304f60a1ed2d67dfd6efd1e"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a1939986d8304f60a1ed2d67dfd6efd1e">calico::sensors::Accelerometer::SetMeasurementNoise</a></div><div class="ttdeci">absl::Status SetMeasurementNoise(double sigma) final</div><div class="ttdoc">Set the measurement noise .</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:178</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a3461a72e36066b1e22778a18525873bf"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a3461a72e36066b1e22778a18525873bf">calico::sensors::Accelerometer::GetExtrinsics</a></div><div class="ttdeci">const Pose3d &amp; GetExtrinsics() const final</div><div class="ttdoc">Getter for extrinsics parameters.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:143</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a35c7bedfecf5338f29bd3518476eed29"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a35c7bedfecf5338f29bd3518476eed29">calico::sensors::Accelerometer::SetModel</a></div><div class="ttdeci">absl::Status SetModel(AccelerometerIntrinsicsModel accelerometer_model)</div><div class="ttdoc">Setter for accelerometer model.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:191</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a3bbd02b0dec4641a5b012dc19f4dd006"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a3bbd02b0dec4641a5b012dc19f4dd006">calico::sensors::Accelerometer::GetModel</a></div><div class="ttdeci">AccelerometerIntrinsicsModel GetModel() const</div><div class="ttdoc">Getter for accelerometer model.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:202</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a4b441d544eafab8b86c867a27b5147a8"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a4b441d544eafab8b86c867a27b5147a8">calico::sensors::Accelerometer::SetLossFunction</a></div><div class="ttdeci">void SetLossFunction(utils::LossFunctionType loss, double scale) final</div><div class="ttdoc">Setter for loss function and scale.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:186</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a572707e00c6b6acc67e61699ca8c436d"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a572707e00c6b6acc67e61699ca8c436d">calico::sensors::Accelerometer::ClearMeasurements</a></div><div class="ttdeci">void ClearMeasurements()</div><div class="ttdoc">Clear all measurements.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:233</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a60bb4adcaedefd9022a7771445618fba"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a60bb4adcaedefd9022a7771445618fba">calico::sensors::Accelerometer::NumberOfMeasurements</a></div><div class="ttdeci">int NumberOfMeasurements() const</div><div class="ttdoc">Get current number of measurements stored.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:237</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a69c802ad172b3875992298cbde1399e1"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a69c802ad172b3875992298cbde1399e1">calico::sensors::Accelerometer::SetName</a></div><div class="ttdeci">void SetName(const std::string &amp;name) final</div><div class="ttdoc">Setter for name.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:134</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a6a4922add5c71301ac6dd55a63a2ea96"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a6a4922add5c71301ac6dd55a63a2ea96">calico::sensors::Accelerometer::GetLatency</a></div><div class="ttdeci">double GetLatency() const final</div><div class="ttdoc">Getter for sensor latency.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:130</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_a7a7b63e21eb8358ba98f78ee9cdb5d25"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#a7a7b63e21eb8358ba98f78ee9cdb5d25">calico::sensors::Accelerometer::ClearResidualInfo</a></div><div class="ttdeci">void ClearResidualInfo() final</div><div class="ttdoc">Clear all stored info about residuals.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:71</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_aa6bd00426c947a719e8889a8c9671447"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#aa6bd00426c947a719e8889a8c9671447">calico::sensors::Accelerometer::UpdateResiduals</a></div><div class="ttdeci">absl::Status UpdateResiduals(ceres::Problem &amp;problem) final</div><div class="ttdoc">Update residuals for this sensor.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:58</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_aaa70cd751e2a85322a44461df1ba8b41"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#aaa70cd751e2a85322a44461df1ba8b41">calico::sensors::Accelerometer::EnableExtrinsicsEstimation</a></div><div class="ttdeci">void EnableExtrinsicsEstimation(bool enable) final</div><div class="ttdoc">Enable or disable extrinsics estimation.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:166</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_aaaac1bf62c3b01d64ce320d5cde74453"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#aaaac1bf62c3b01d64ce320d5cde74453">calico::sensors::Accelerometer::AddMeasurements</a></div><div class="ttdeci">absl::Status AddMeasurements(const std::vector&lt; AccelerometerMeasurement &gt; &amp;measurements)</div><div class="ttdoc">Add multiple measurements to the measurement list.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:218</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_aab53d1ea391bcffe744ad1c5e77ea893"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#aab53d1ea391bcffe744ad1c5e77ea893">calico::sensors::Accelerometer::SetLatency</a></div><div class="ttdeci">absl::Status SetLatency(double latency) final</div><div class="ttdoc">Setter for sensor latency.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:125</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_ac11dda7c2c1c93091c5d3544b867a761"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#ac11dda7c2c1c93091c5d3544b867a761">calico::sensors::Accelerometer::GetName</a></div><div class="ttdeci">const std::string &amp; GetName() const final</div><div class="ttdoc">Getter for name.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:137</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_ac1e574412a12a2dad447b6a7b3fe2855"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#ac1e574412a12a2dad447b6a7b3fe2855">calico::sensors::Accelerometer::Project</a></div><div class="ttdeci">absl::StatusOr&lt; std::vector&lt; AccelerometerMeasurement &gt; &gt; Project(const std::vector&lt; double &gt; &amp;interp_times, const Trajectory &amp;sensorrig_trajectory, const WorldModel &amp;world_model) const</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:76</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_ac67ee592eac447f77f3570cc3d1f7955"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#ac67ee592eac447f77f3570cc3d1f7955">calico::sensors::Accelerometer::EnableIntrinsicsEstimation</a></div><div class="ttdeci">void EnableIntrinsicsEstimation(bool enable) final</div><div class="ttdoc">Enable or disable intrinsics estimation.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:170</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_ac9cdfe615bc666967c5c72231cd23b60"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#ac9cdfe615bc666967c5c72231cd23b60">calico::sensors::Accelerometer::EnableLatencyEstimation</a></div><div class="ttdeci">void EnableLatencyEstimation(bool enable) final</div><div class="ttdoc">Enable or disable latency estimation.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:174</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_acd8424db4c5a76a33a113963e763eaa6"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#acd8424db4c5a76a33a113963e763eaa6">calico::sensors::Accelerometer::SetIntrinsics</a></div><div class="ttdeci">absl::Status SetIntrinsics(const Eigen::VectorXd &amp;intrinsics) final</div><div class="ttdoc">Setter for intrinsics parameters.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:147</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_ad662a04d9dc1fa620d674260a10ef584"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#ad662a04d9dc1fa620d674260a10ef584">calico::sensors::Accelerometer::AddParametersToProblem</a></div><div class="ttdeci">absl::StatusOr&lt; int &gt; AddParametersToProblem(ceres::Problem &amp;problem) final</div><div class="ttdoc">Add this sensor's calibration parameters to the ceres problem.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:10</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Accelerometer_html_ae3b0b45306c07f8af56bcd42cdc3cbab"><div class="ttname"><a href="classcalico_1_1sensors_1_1Accelerometer.html#ae3b0b45306c07f8af56bcd42cdc3cbab">calico::sensors::Accelerometer::AddMeasurement</a></div><div class="ttdeci">absl::Status AddMeasurement(const AccelerometerMeasurement &amp;measurement)</div><div class="ttdoc">Add an accelerometer measurement to the measurement list.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:207</div></div>
<div class="ttc" id="aclasscalico_1_1sensors_1_1Sensor_html"><div class="ttname"><a href="classcalico_1_1sensors_1_1Sensor.html">calico::sensors::Sensor</a></div><div class="ttdef"><b>Definition:</b> sensor_base.h:22</div></div>
<div class="ttc" id="anamespacecalico_1_1sensors_html"><div class="ttname"><a href="namespacecalico_1_1sensors.html">calico::sensors</a></div><div class="ttdoc">Sensors namespace.</div><div class="ttdef"><b>Definition:</b> accelerometer.cpp:8</div></div>
<div class="ttc" id="anamespacecalico_1_1sensors_html_a911841171d662dc3e4bf4b39463a4c42"><div class="ttname"><a href="namespacecalico_1_1sensors.html#a911841171d662dc3e4bf4b39463a4c42">calico::sensors::AccelerometerIntrinsicsModel</a></div><div class="ttdeci">AccelerometerIntrinsicsModel</div><div class="ttdoc">Accelerometer model types.</div><div class="ttdef"><b>Definition:</b> accelerometer_models.h:16</div></div>
<div class="ttc" id="anamespacecalico_1_1utils_html_aacede3df540b75d2e131f113380f0ce9"><div class="ttname"><a href="namespacecalico_1_1utils.html#aacede3df540b75d2e131f113380f0ce9">calico::utils::LossFunctionType</a></div><div class="ttdeci">LossFunctionType</div><div class="ttdef"><b>Definition:</b> optimization_utils.h:15</div></div>
<div class="ttc" id="astructcalico_1_1sensors_1_1AccelerometerMeasurement_html"><div class="ttname"><a href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html">calico::sensors::AccelerometerMeasurement</a></div><div class="ttdoc">Accelerometer measurement type.</div><div class="ttdef"><b>Definition:</b> accelerometer.h:41</div></div>
<div class="ttc" id="astructcalico_1_1sensors_1_1AccelerometerMeasurement_html_a22dd6e5ae79698f60cb08f060e36be46"><div class="ttname"><a href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html#a22dd6e5ae79698f60cb08f060e36be46">calico::sensors::AccelerometerMeasurement::id</a></div><div class="ttdeci">AccelerometerObservationId id</div><div class="ttdoc">Id of this observation.</div><div class="ttdef"><b>Definition:</b> accelerometer.h:45</div></div>
<div class="ttc" id="astructcalico_1_1sensors_1_1AccelerometerMeasurement_html_ac08ec8f7529613c599bc84a25900df96"><div class="ttname"><a href="structcalico_1_1sensors_1_1AccelerometerMeasurement.html#ac08ec8f7529613c599bc84a25900df96">calico::sensors::AccelerometerMeasurement::measurement</a></div><div class="ttdeci">Eigen::Vector3d measurement</div><div class="ttdoc">Raw uncalibrated measurement value from an accelerometer.</div><div class="ttdef"><b>Definition:</b> accelerometer.h:43</div></div>
<div class="ttc" id="astructcalico_1_1sensors_1_1AccelerometerObservationId_html"><div class="ttname"><a href="structcalico_1_1sensors_1_1AccelerometerObservationId.html">calico::sensors::AccelerometerObservationId</a></div><div class="ttdef"><b>Definition:</b> accelerometer.h:23</div></div>
<div class="ttc" id="astructcalico_1_1sensors_1_1AccelerometerObservationId_html_a4e90d646ca44f8d9b7bff65c95d6462c"><div class="ttname"><a href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a4e90d646ca44f8d9b7bff65c95d6462c">calico::sensors::AccelerometerObservationId::stamp</a></div><div class="ttdeci">double stamp</div><div class="ttdoc">Timestamp in seconds.</div><div class="ttdef"><b>Definition:</b> accelerometer.h:25</div></div>
<div class="ttc" id="astructcalico_1_1sensors_1_1AccelerometerObservationId_html_a8713942f102169b91a719ca40f42d9ac"><div class="ttname"><a href="structcalico_1_1sensors_1_1AccelerometerObservationId.html#a8713942f102169b91a719ca40f42d9ac">calico::sensors::AccelerometerObservationId::sequence</a></div><div class="ttdeci">int sequence</div><div class="ttdoc">Sequence number of this measurement.</div><div class="ttdef"><b>Definition:</b> accelerometer.h:27</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1
</small></address>
</body>
</html>
